﻿using ChurchDiary.BLL;
using ChurchDiary.TableEntity;
using System;
using System.Collections.Generic;
using System.Linq;
using System.Web;
using System.Web.Mvc;

namespace ChurchDiary.Promotion.Controllers
{
    public class HomeController : Controller
    {
        public ActionResult Index()
        {
            return View();
        }
        public ActionResult SaveContactUs()
        {
            EntityContactUs ContactUs = new EntityContactUs();
            ContactUs.Name = Request.Form["Name"].ToString();
            ContactUs.Phone = Request.Form["Email"].ToString();
            ContactUs.Email = Request.Form["ContactNo"].ToString();
            ContactUs.Message = Request.Form["Message"].ToString();
            TempData["Result"]  = new BLL_Promotion().InsertContactUs(ContactUs);
            return RedirectToAction("Index");
        }
    }
}